package au.com.evoCoach.dao;

import java.util.List;

import org.hibernate.Query;
import org.springframework.stereotype.Repository;

import au.com.evoCoach.domain.League;
import au.com.evoCoach.domain.Player;
import au.com.evoCoach.domain.Team;
import au.com.evoCoach.domain.TeamPlayer;

@Repository
public class PlayerDAO extends BaseDAO {

	public PlayerDAO() {
		super(Player.class);
	}

	public List<Player> getAllPlayers() {
		String sql = "from Player";
       	Query query = getSession().createQuery(sql);
      	return query.list();
	}
}
